package com.itheima;

/**
 * 2025/5/15 8:20
 */
public class TestB {
    public static void main(String[] args) {

        B b1 = new B() {
            @Override
            public void show(String name) {
                System.out.println("name = "+name);
            }
        };

        B b2 = xxx->
                System.out.println("name = "+xxx);

        TestB testB = new TestB();
        B b3 = testB::show;
        b3.show("张三");

    }

    public void show(String name){
        System.out.println("name = "+name);
    }

}
